﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Zeus.Thunder.Core;
using SharpTrainer.Util;

namespace SharpTrainer.Xml
{
    class XmlSerializeTest : ITestCase
    {
        public void Run()
        {
            List<MyEmployee> employees = new List<MyEmployee>()
                                      {
                                          new MyEmployee { Name = "David", Salary = 50000 },
                                          new MyEmployee { Name = "Peter", Salary = 10000 },
                                          new MyEmployee { Name = "Mary", Salary = 6000 }
                                      };
            XmlUtil.SerializeToXml<List<MyEmployee>>(employees, @"D:\\employee.xml");
            Console.WriteLine("Xml Serialization Successful!");
        }
    }
}
